#include <STC15F2K60S2.H>
#include "Relay.h"
#include "Key.h"

	
/**********************************************************************/
//定时器2初始化函数
/**********************************************************************/
void Timer2_Init(void)		//500微秒@11.0592MHz
{
	AUXR |= 0x04;		//定时器时钟1T模式
	T2L = 0xAE;		//设置定时初值
	T2H = 0xFB;		//设置定时初值
	IE2 |= 0x04;		//允许定时器2产生中断
	EA = 1;				//中断总开关
	AUXR |= 0x10;		//定时器2开始计时
}

